<script setup>
defineProps({
  title: {
    required: true,
    type: String
  }
})
</script>
<template>
  <el-card class="slot-header">
    <template #header>
      <div class="header">
        <span>{{ title }}</span>
        <slot name="extra"></slot>
      </div>
    </template>
    <slot></slot>
  </el-card>
</template>
<style scoped>
.slot-header {
  width: 100%;
}
.header {
  display: flex;
  justify-content: space-between;
}
</style>
